home *** CD-ROM | disk | FTP | other *** search
/ Monster Media 1994 #2 / Monster Media No. 2 (Monster Media)(1994).ISO / wp / xe416.zip / XE.DOC < prev    next >
Text File  |  1994-08-13  |  48KB  |  1,383 lines

  1.  
  2.  
  3.  
  4.  
  5.  
  6.                                Table of Contents
  7.  
  8.      A. Title........................................................... 1
  9.      B. DISCLAIMER...................................................... 2
  10.      C. Introduction.................................................... 3
  11.      D. Starting heXEdit................................................ 4
  12.      E. Command Line Options............................................ 4
  13.      F. Environment Variable - XEOPT.................................... 5
  14.      G. Loadfile box.................................................... 5
  15.         1. File/Directory Attributes.................................... 7
  16.      H. Main Display.................................................... 7
  17.      I. Commands........................................................ 8
  18.         1. Help......................................................... 8
  19.         2. ASCII chart.................................................. 9
  20.         3. Convert a number............................................. 9
  21.         4. Change colors............................................... 10
  22.         5. Decimal offset ............................................. 11
  23.         6. Shell out to DOS prompt or another program.................. 11
  24.         7. Edit........................................................ 11
  25.         8. Goto an offset.............................................. 13
  26.         9. Hexadecimal offset ......................................... 14
  27.         10. Load a new file............................................ 14
  28.         11. Push position on marker stack.............................. 14
  29.         12. Search again............................................... 14
  30.         13. Octal offset .............................................. 14
  31.         14. Retrieve position from marker stack........................ 15
  32.         15. Search..................................................... 15
  33.         16. Clear marker stack......................................... 16
  34.         17. Goto marked position....................................... 16
  35.      J. Other Notes.................................................... 16
  36.      K. Comments....................................................... 17
  37.      L. Appendix....................................................... 17
  38.         1. Version History............................................. 17
  39.         2. Trademark information....................................... 20
  40.  
  41.  
  42.  
  43.  
  44.  
  45.  
  46.  
  47.  
  48.  
  49.  
  50.  
  51.  
  52.  
  53.  
  54.  
  55.  
  56.  
  57.  
  58.  
  59.  
  60.  
  61.  
  62.  
  63.  ---  heXEdit  -------------------------------------  Page i  ---
  64.  
  65.  
  66.  
  67.  
  68.  
  69.  
  70.  
  71.  
  72. A. Title
  73.  
  74.  
  75.  
  76.                                     heXEdit
  77.  
  78.  
  79.  
  80.                                   Version 4.16
  81.  
  82.                                     8-13-94
  83.  
  84.  
  85.  
  86.  
  87.  
  88.  
  89.  
  90.  
  91.                                  Robert Stuntz
  92.                             565 Dorothy Dr.  Apt. 1
  93.                             Des Plaines, IL.  60016
  94.                                      U.S.A.
  95.  
  96.                              CompuServe : 71043,117
  97.  
  98.  
  99.  
  100.  
  101.  
  102.  
  103.  
  104.  
  105.  
  106.  
  107.  
  108.  
  109.  
  110.  
  111.  
  112.  
  113.  
  114.  
  115.  
  116.  
  117.  
  118.  
  119.  
  120.  
  121.  
  122.  
  123.  
  124.  
  125.  
  126.  
  127.  
  128.  
  129.  ---  heXEdit  -------------------------------------  Page 1  ---
  130.  
  131.  
  132.  
  133.  
  134.  
  135.  
  136.  
  137.  
  138. B.  DISCLAIMER
  139.  
  140.        THIS SOFTWARE AND MANUAL ARE DISTRIBUTED "AS IS" AND WITHOUT
  141.        WARRANTIES AS TO PERFORMANCE OF MERCHANTABILITY OR ANY OTHER
  142.        WARRANTIES WHETHER EXPRESSED OR IMPLIED.  BECAUSE OF THE VARIOUS
  143.        HARDWARE AND SOFTWARE ENVIRONMENTS INTO WHICH THIS PROGRAM MAY BE
  144.        PUT, NO WARRANTY OF FITNESS FOR A PARTICULAR PURPOSE IS OFFERED AND
  145.        ALL LIABILITY IN THE USE AND EFFECTS OF THIS PROGRAM SHALL REST
  146.        WITH THE USER.
  147.  
  148.        THIS PROGRAM HAS THE ABILITY TO ALTER YOUR FILES! YOU ARE
  149.        RESPONSIBLE!  (Sorry, but I have to warn you ...)
  150.  
  151.  
  152.  
  153.  
  154.  
  155.  
  156.  
  157.  
  158.  
  159.  
  160.  
  161.  
  162.  
  163.  
  164.  
  165.  
  166.  
  167.  
  168.  
  169.  
  170.  
  171.  
  172.  
  173.  
  174.  
  175.  
  176.  
  177.  
  178.  
  179.  
  180.  
  181.  
  182.  
  183.  
  184.  
  185.  
  186.  
  187.  
  188.  
  189.  
  190.  
  191.  
  192.  
  193.  
  194.  
  195.  ---  heXEdit  -------------------------------------  Page 2  ---
  196.  
  197.  
  198.  
  199.  
  200.  
  201.  
  202.  
  203.  
  204. C. Introduction
  205.  
  206.  
  207.  
  208.         heXEdit (XE) is a program that will allow you to display and/or
  209.         edit any file. It doesn't have a fancy interface but serves my
  210.         purposes perfectly. I wrote this program because I became
  211.         frustrated with a couple of other commercial programs. They either
  212.         had some annoying peculiarities or required too much thought on my
  213.         part just to search for and change a couple of bytes.
  214.  
  215.  
  216.         heXEdit was written using Turbo Pascal v6.0, although it doesn't
  217.         use any of Borland's object libraries. It does however write
  218.         directly to video memory for speed when scrolling thru the file.
  219.         If you're using a CGA monitor you may see some 'snow' as I don't
  220.         check for the vertical retrace period before writing to video
  221.         memory.
  222.  
  223.  
  224.         heXEdit will keep no more than 1760 bytes of the file you load in
  225.         memory at a time, as I didn't feel like messing with a variable
  226.         amount of memory available. heXEdit requires about 130k bytes of
  227.         free memory in order to execute.
  228.  
  229.  
  230.  
  231.  
  232.  
  233.  
  234.  
  235.  
  236.  
  237.  
  238.  
  239.  
  240.  
  241.  
  242.  
  243.  
  244.  
  245.  
  246.  
  247.  
  248.  
  249.  
  250.  
  251.  
  252.  
  253.  
  254.  
  255.  
  256.  
  257.  
  258.  
  259.  
  260.  
  261.  ---  heXEdit  -------------------------------------  Page 3  ---
  262.  
  263.  
  264.  
  265.  
  266.  
  267.  
  268.  
  269.  
  270. D. Starting heXEdit
  271.  
  272.  
  273.         To start heXEdit, enter
  274.  
  275.         XE [options] [<drive>:][<filename>] [options]
  276.  
  277.  
  278.         The drive designator, filename and options are ... optional on the
  279.         command line. If only a drive designator is specified, XE will
  280.         show you the files from that drive's current directory.  If a file
  281.         is specified XE will try to load that file, if not, you will see a
  282.         list of files from the current directory. All of the available
  283.         command line options are explained in the following section.
  284.  
  285.  
  286. E. Command Line Options
  287.  
  288.  
  289.         Available command line options are as follows :
  290.  
  291.     1. /C or /M
  292.  
  293.        /C  This option tells XE to use it's default color set.
  294.  
  295.        /M  This option tells XE to use black and white colors; for
  296.            monochrome monitors.
  297.  
  298.     3. /? or /H
  299.  
  300.         Either of these two options will display a short message about the
  301.         start-up syntax.
  302.  
  303.     4. /Lc[c[c]]
  304.  
  305.         The files and directories in the Loadfile box (described in the
  306.         next section) are sorted, depending on the value of this option.
  307.  
  308.         /L is followed by 1-3 characters listed below which describe the
  309.         actual sort options.
  310.  
  311.         c = U, D, F   N, E, S, T   A, Z
  312.  
  313.                 (group 1)
  314.                 U - unsorted; directory and file entries are listed as
  315.                     they are read from the disk, then list drive
  316.                     designators
  317.                 D - put directory entries at the top of the list, followed
  318.                     by files, then drive designators
  319.                     (default)
  320.                 F - put file entries at the top of the list, followed by
  321.                     directories, then drive designators
  322.  
  323.                 (group 2)
  324.  
  325.  
  326.  
  327.  ---  heXEdit  -------------------------------------  Page 4  ---
  328.  
  329.  
  330.  
  331.  
  332.  
  333.  
  334.  
  335.  
  336.                 N - sort files/dirs by name
  337.                     (default)
  338.                 E - sort files/dirs by extension then name
  339.                     (sorting by ext slows down the speed at which the list
  340.                     is sorted and displayed, more than the other options)
  341.                 S - sort files by size, dirs by name
  342.                     (physical size of dir entry irrelevant)
  343.                 T - sort files/dirs by date/time
  344.  
  345.                 (group 3)
  346.                 A - sort files/dirs in ascending order
  347.                     (default)
  348.                 Z - sort files/dirs in descending order
  349.  
  350.  
  351.         Note that it is possible to specify options that are in conflict
  352.         with each other. However, the last option specified belonging to
  353.         each group is the one used. For example, you could use /LDNF, and
  354.         in this case the F would take precedence over the D. For /LES, the
  355.         S will take precedence. If you do not specify an option for a
  356.         group, a default value will be used (D for group 1, N for group 2,
  357.         and A for group 3).
  358.  
  359.         If there is an invalid option or sub-option specified, XE will
  360.         exit with an error message.
  361.  
  362.  
  363. F. Environment Variable - XEOPT
  364.  
  365.         All of the command line options can also be specified thru an
  366.         environment variable called 'XEOPT'. To set the value of XEOPT,
  367.         use the DOS SET command at a DOS prompt before running XE. For
  368.         example:
  369.  
  370.                 SET XEOPT=/LFEA/C
  371.  
  372.         If command line options are used, they will override environment
  373.         variable options if they conflict with each other.
  374.  
  375.  
  376. G. Loadfile box
  377.  
  378.         If a drive designator is specified on the command line, XE will
  379.         show you the files from that drive's current directory. If a file
  380.         is specified XE will try to load that file, if not, you will see a
  381.         list of files from the current directory of the current drive. If
  382.         a file or directory has it's hidden attribute set, it will be
  383.         displayed in lower case. At the end of the list, you will see one
  384.         or more drive designators. The drives you can choose from are all
  385.         the available drives, including remote (or network) drives.  If a
  386.         drive is a removeable media device (like a floppy drive), then you
  387.         will see the characters '(  )' surrounding the drive letter.  If a
  388.         drive is a fixed media device (like a hard disk drive), then you
  389.         will see the characters '[  ]' surrounding the drive letter.  If a
  390.  
  391.  
  392.  
  393.  ---  heXEdit  -------------------------------------  Page 5  ---
  394.  
  395.  
  396.  
  397.  
  398.  
  399.  
  400.  
  401.  
  402.         drive is a remote device, whether it's fixed or removeable, then
  403.         you will see the characters '{  }' surrounding the drive letter.
  404.         If a drive is local and fixed, then the VolumeID will be displayed
  405.         to the right of the drive letter.  Selecting one of these will
  406.         show you the contents of that drive's current directory.
  407.  
  408.         To load a file, simply use the UP and DOWN arrow keys to move the
  409.         highlight bar to the file you want to load, then press ENTER. You
  410.         can also use the PAGEUP and PAGEDOWN keys to scroll thru the list
  411.         of files a page at a time. Pressing the HOME key will move you to
  412.         the top of the list, pressing END moves you to the end of the
  413.         list.
  414.  
  415.         New with version 4.1 * You can now do a 'hypersearch' to jump
  416.         right to a file, directory, or drive designator rather than
  417.         scrolling thru the list. While in the Loadfile box, if you press a
  418.         letter or number, or any other valid filename character, the
  419.         highlight bar will move to the first file or directory whose name
  420.         begins with the character you pressed. The search starts from your
  421.         current highlight bar position and stops at the first match it
  422.         finds. It will wrap around to the top, if nothing matches, and
  423.         continue searching up to your current position. If no match is
  424.         found, you will hear a short, low pitch beep. XE will also check
  425.         the drive designator entries, at the end of the list, for your
  426.         'hyper-character'. For ex., if you don't have any files or
  427.         directories that start with the letter 'B', and you press 'B', the
  428.         highlight bar will move to the drive designator '[ - B: - ]'.
  429.         Pressing the period '.' key will move you to the directory entry
  430.         of '..' (the parent directory label).
  431.  
  432.         Also new with version 4.1 * On the left border of the Loadfile box
  433.         is a percentage indicator (either '', '', or '' - ascii codes
  434.         #25, #18, #24) of how far up or down you are in the list of
  435.         files/directories. When you (the highlight bar) are at the first
  436.         file/directory in the list, the indicator is at the top of the
  437.         border. If you are 70% of the way down the list, the indicator is
  438.         about 70% of the way down the border; etc, etc. It is there as a
  439.         quick reference, not an exact measurement. * And on the right
  440.         border, the options that you specified (or the default options)
  441.         for the Loadfile box sort options (/L) will be displayed.
  442.  
  443.         Pressing ENTER on a directory entry or a drive letter will change
  444.         to that directory or drive.
  445.  
  446.  
  447.         While using the Loadfile box, you may encounter an error, for one
  448.         reason or another. Generally speaking, you will be given one, some
  449.         or all of the options below :
  450.  
  451.           1 - (A)bort : if you press 'A' XE will abort the operation.
  452.  
  453.           2 - (R)etry : press 'R' to retry the operation. (Maybe the
  454.               drive door was opened before you hit ENTER to load the
  455.               file.)
  456.  
  457.  
  458.  
  459.  ---  heXEdit  -------------------------------------  Page 6  ---
  460.  
  461.  
  462.  
  463.  
  464.  
  465.  
  466.  
  467.  
  468.           3 - (Q)uit XE : press 'Q' to quit XE and return to the DOS
  469.               prompt (or wherever it was that you came from).
  470.  
  471.           4 - Any other key : if you hit any other key than the ones
  472.               described above you will be returned to the Loadfile box.
  473.  
  474.  
  475.         While in the Loadfile box, pressing ESC will exit the Loadfile box
  476.         and either 1) return you to the last file you were viewing, or 2)
  477.         if no file was previously loaded, exit XE altogether.
  478.  
  479.  
  480.  
  481.  
  482.   1. File/Directory Attributes
  483.  
  484.         One last feature of the Loadfile box is that you can change the
  485.         attributes of a file simply by pressing F5-F8 (providing the file
  486.         is available; i.e., the disk is in the drive etc). And starting
  487.         with version 3.64, you can also change the Hidden attribute bit of
  488.         a subdirectory. Move the highlight bar to the file you want to
  489.         work with and then simply press one of the following keys,
  490.         depending on what you want to do.
  491.  
  492.                 F5 - toggles the Archive bit
  493.                 F6 - toggles the System bit
  494.                 F7 - toggles the Hidden bit
  495.                 F8 - toggles the Read_Only bit
  496.  
  497.         If the attribute change was successful you will hear a high pitch
  498.         tone, otherwise you will hear a low tone indicating that the
  499.         attribute could not be changed for one reason or another.  You
  500.         should also see the attribute change in the Loadfile box if the
  501.         change was successful.
  502.  
  503.     *** NOTE : Be sure you know what affect changing an attribute will
  504.         have on your system. Some programs act on the attributes of a
  505.         file or may even require certain attributes to be set.
  506.  
  507.  
  508. H. Main Display
  509.  
  510.  
  511.         Once the file is loaded you will see the main display.  At the top
  512.         is the name of the file loaded. On the left side of the display
  513.         are numbers (in hexadecimal,decimal or octal) indicating the
  514.         offset into the file. In the middle are 22 rows of 16 bytes which
  515.         are the file's contents. On the right, the ASCII character for
  516.         each byte in that row. In the ASCII portion of the display, any
  517.         characters past the EOF (end-of-file) are shown as a '.' (ASCII
  518.         #249). On the bottom is a status word indicating your current
  519.         operation, a three letter abbrev indicating whether the offset
  520.         display is in 'hex'adecimal, 'dec'imal, or 'oct'al, the percentage
  521.         into the file from the top line, and the size of the file in
  522.  
  523.  
  524.  
  525.  ---  heXEdit  -------------------------------------  Page 7  ---
  526.  
  527.  
  528.  
  529.  
  530.  
  531.  
  532.  
  533.  
  534.         decimal.
  535.  
  536.  
  537. I. Commands
  538.  
  539.  
  540.         Following is a list of commands once you are in XE and then a
  541.         brief explanation of each :
  542.  
  543.  
  544.         F1      - Help
  545.         A/Alt+A - ASCII table
  546.         B/Alt+B - Base conversion (decimal-hexadecimal-binary)
  547.         C       - Change colors
  548.         D       - Change offset display to Decimal
  549.         Alt+D   - Shell out to a DOS prompt, or other program
  550.         E       - Edit the file
  551.         G       - Goto offset
  552.         H       - Change offset display to Hexadecimal
  553.         L       - Bring up the Loadfile box
  554.         M       - Push position on marker stack
  555.         N       - Search again (using the last used search string)
  556.         O       - Change offset display to Octal
  557.         R       - Retrieve position from marker stack
  558.         S       - Search (for text or a byte string)
  559.         Z       - Clear all entries from marker stack
  560.         ALT+1 thru ALT+9 - Goto marked position
  561.  
  562.         UP/DOWN arrow keys - scroll up and down one line at a time
  563.         PAGEUP/PAGEDOWN    - move up/down one page at a time
  564.         HOME               - move to the beginning of the file
  565.         END                - move to the end of the file
  566.         ESC/Alt+X          - quit XE
  567.  
  568.  
  569.  
  570.   1. Help
  571.  
  572.         F1
  573.  
  574.         Pressing F1 will display a help screen. You now have the following
  575.         commands available :
  576.  
  577.         F1 : Help on Help
  578.         F2 : Display index (keywords) for items in the help file
  579.         F3 : Goto the previous screen (limited)
  580.         F5 : Zoom/Unzoom the help screen
  581.  
  582.         ENTER           : Get help on a highlighted keyword
  583.         Arrow keys      : Scroll the help screen contents left, right,
  584.                           up and down
  585.         ESC             : Exits help
  586.         TAB / SHFT+TAB  : Highlight the next/previous visible
  587.                           keyword
  588.  
  589.  
  590.  
  591.  ---  heXEdit  -------------------------------------  Page 8  ---
  592.  
  593.  
  594.  
  595.  
  596.  
  597.  
  598.  
  599.  
  600.         PAGEUP/PAGEDOWN : Move up and down a page at a time
  601.         HOME/END        : Goto the beginning/end of the help info for
  602.                           the current item
  603.  
  604.  
  605.  
  606.         In the upper left corner of the help screen (in the border), you
  607.         may see a number and possibly one of three arrow characters. The
  608.         number is the left column, of the help info, you are at. If you
  609.         are at column one, it will not be displayed.  The arrow characters
  610.         indicate if there is more info either above or below (or both) of
  611.         your position.
  612.  
  613.  
  614.         A couple of notes on the help file.
  615.  
  616.         1. heXEdit expects the help file (XE.HLP) to be in the directory
  617.         that XE.EXE is in. If it is not, you will get an error message
  618.         when you invoke help.
  619.  
  620.         2. If you modify the help file, make sure your keywords are
  621.         capitalized and start in column one. It will probably be easier to
  622.         just look at the help file that came with heXEdit to see how it's
  623.         done.
  624.  
  625.         3. There is a limit of 75 lines of information per keyword.
  626.  
  627.         4. Keyword information begins with it's keyword and ends with a
  628.         slash (#47).
  629.  
  630.         5. To create a keyword in a help screen, precede the keyword with
  631.         a tilde (#126) and end it with a back-quote (#96).
  632.  
  633.  
  634.  
  635.   2. ASCII chart
  636.  
  637.         A or Alt+A
  638.  
  639.         Display an ASCII chart.
  640.  
  641.         ASCII chart commands :
  642.           LEFT arrow key  : go back 16 characters
  643.           RIGHT arrow key : go forward 16 characters
  644.           PAGEUP          : go back 128 characters
  645.           PAGEDOWN        : go forward 128 characters
  646.           D               : display numbers in decimal
  647.           H               : display numbers in hexadecimal
  648.           ESC or ENTER    : exits ASCII chart
  649.  
  650.  
  651.   3. Convert a number
  652.  
  653.         B or Alt+B
  654.  
  655.  
  656.  
  657.  ---  heXEdit  -------------------------------------  Page 9  ---
  658.  
  659.  
  660.  
  661.  
  662.  
  663.  
  664.  
  665.  
  666.         Convert a number from either decimal, hexadecimal or binary to the
  667.         other two.
  668.  
  669.         Base convert commands :
  670.           UP/DOWN arrow keys  : select the base of the input number
  671.           ENTER               : convert the number
  672.           ESC                 : exit the base convert routine
  673.  
  674.         Using the arrow keys, move the highlight bar to the base of the
  675.         input number and then either 1) press ENTER and enter the number
  676.         or 2) just start typing the number. After the number has been
  677.         converted, press any key to select the base for another conversion
  678.         or press ESC to exit.
  679.  
  680.         When you enter the number, I only check for validity with the
  681.         first character. If you try to convert an invalid number an error
  682.         message will be displayed. The largest number that can be
  683.         accurately converted is a 32 bit number. It has a very simple
  684.         input routine, so don't be surprised if you can enter an invalid
  685.         number.  The conversion will be incorrect of course. I leave it
  686.         mostly up to you to enter a valid number.
  687.  
  688.  
  689.   4. Change colors
  690.  
  691.         C
  692.  
  693.         This command will allow you to change the color of just about
  694.         anything. You can also save the colors you choose so that XE will
  695.         startup with those colors.
  696.  
  697.         Simply select the area you want to change the color in by pressing
  698.         a letter 'A' thru 'O'. A colorbox of all possible colors will
  699.         appear. The current color of the item you selected will have two
  700.         white bars on either side of an 'X'. You can now move those white
  701.         bars around with the arrow keys to select a new color. With the
  702.         white bars around the color scheme you want, press ENTER. If you
  703.         change your mind and don't want to change the color of that item,
  704.         press ESC.
  705.  
  706.         There are a couple areas that have a color selection restriction.
  707.         Area 'G', Altered bytes background, you can only select the
  708.         background, the foreground is the same as the main bytes (area
  709.         'A'). And the border for Help, only the foreground can be selected
  710.         as it's background is the same as the Help text (area 'L').
  711.  
  712.         Color Change Commands :
  713.  
  714.         F1        : get help
  715.         A-O       : select the area you want to change
  716.         S         : save the currently selected colors to XE.EXE
  717.         ESC/ENTER : exit the color change screen
  718.  
  719.         The 'S' command will save the currently selected colors to the
  720.  
  721.  
  722.  
  723.  ---  heXEdit  -------------------------------------  Page 10  ---
  724.  
  725.  
  726.  
  727.  
  728.  
  729.  
  730.  
  731.  
  732.         executable file (XE.EXE). If XE.EXE is not available where it was
  733.         started from, an error message will be displayed to that effect,
  734.         which means your colors have not been saved.
  735.  
  736.         If you want the default colors back, start-up XE with the /C
  737.         option. If you want to retain the default colors make sure you
  738.         then save the colors, otherwise the next time you start XE you
  739.         will have whatever colors were last saved in XE.EXE.
  740.  
  741.  
  742.   5. Decimal offset #'s
  743.  
  744.         D
  745.  
  746.         Change the offset display to base 10, decimal.
  747.  
  748.  
  749.   6. Shell out to DOS prompt or another program
  750.  
  751.         Alt+D
  752.  
  753.         This command will shell out to a DOS prompt or another program.
  754.  
  755.         When this command is pressed, XE first looks for an environment
  756.         variable called XESHELL. If found, XE will try to run the program
  757.         name specified by that environment variable. When using XESHELL,
  758.         the entire pathname needs to be used if the program you want to
  759.         shell too is not in your current directory. XE does not search the
  760.         directories in your PATH for the program specified.  Also, the
  761.         program specified has to have an extension of EXE or COM and
  762.         command line parameters can be included. The following is an
  763.         example of how to set the value of XESHELL (from a DOS prompt):
  764.  
  765.                 SET XESHELL=C:\UT\LIST.COM /4
  766.  
  767.         If XE does not find a value for XESHELL, it looks for COMSPEC. The
  768.         rules above also apply to COMSPEC. COMSPEC is normally set to the
  769.         command processor COMMAND.COM. If neither environment variable
  770.         exists, you will receive an error message stating so.
  771.  
  772.         If COMMAND.COM is the program shelled to, typing EXIT will return
  773.         you to heXEdit. If XESHELL is used to run a different program,
  774.         exiting that program will return you to heXEdit.
  775.  
  776.  
  777.   7. Edit
  778.  
  779.         E
  780.  
  781.         Begin editing the file at the current position.  If the file is a
  782.         READ ONLY file, a short message to that affect will appear and you
  783.         will be returned to the view mode. Of course, you could just press
  784.         'L' to bring up the Loadfile box and change the READ ONLY
  785.         attribute of the file with F8.  And then go back and edit.  But,
  786.  
  787.  
  788.  
  789.  ---  heXEdit  -------------------------------------  Page 11  ---
  790.  
  791.  
  792.  
  793.  
  794.  
  795.  
  796.  
  797.  
  798.         it might be READ ONLY for a reason ...
  799.  
  800.         If you had previously searched the file successfully (meaning you
  801.         found an item) then if that exact item is displayed on screen when
  802.         you go to edit mode, then the cursor will be positioned at the
  803.         first character of that item. When I say exact item, I mean the
  804.         last item that you found in your search (this does not quite work
  805.         as I'd like it too...).  Also, shown at the bottom is the offset
  806.         of the cursor position.
  807.  
  808.         Edit commands :
  809.           F1              : get help
  810.           Alt+A           : displays the ASCII chart
  811.           Alt+B           : base number conversion
  812.           Alt+D           : shell out to DOS or other prog
  813.  
  814.           BACKSPACE/LEFT arrow key  : move cursor left 1 byte
  815.           RIGHT arrow key : move cursor right 1 byte
  816.           PAGEUP          : move cursor to first line on page
  817.           PAGEDOWN        : move cursor to last line on page
  818.           HOME            : move cursor to beginning of line
  819.           END             : move cursor to end of line
  820.  
  821.           TAB : toggle cursor position between the hexadecimal display
  822.                 and the ASCII display of the file. The above editing
  823.                 commands will move the cursor within the area the
  824.                 cursor is in.  You can edit the file making changes in
  825.                 both areas at the same time, if so desired.
  826.  
  827.           ENTER : quit editing. If you made changes to whole bytes you
  828.                   will be prompted to save the changes or not.  Press
  829.                   'Y' to save the changes or 'N' to lose the changes.
  830.                   Only the portion of the file that is in memory is
  831.                   actually saved. So don't worry about waiting for a
  832.                   long save if you are editing a large file.  You are
  833.                   then returned to the View mode.
  834.  
  835.           ESC : quit editing. If you made changes to whole bytes you will
  836.                 be prompted to discard the changes or not. Press 'Y' to
  837.                 discard the changes and return to view mode, or 'N' to
  838.                 return to edit mode.
  839.  
  840.         After pressing either ENTER or ESC (as above), you can press ESC
  841.         to cancel the request and return to edit mode.
  842.  
  843.         To change a value when in the hexadecimal portion, just type in
  844.         it's new value. The background of the character will change,
  845.         indicating which bytes have been changed.  Valid values are
  846.         $00 - $FF. Obviously, pressing a key like 'P' will do nothing
  847.         because 'P' is not a valid hexadecimal character.
  848.  
  849.         To change a value when in the ASCII portion of the display, simply
  850.         press the key of the new value. Or, hold down the ALT key while
  851.         typing the ASCII code, on the numeric keypad, of the character you
  852.  
  853.  
  854.  
  855.  ---  heXEdit  -------------------------------------  Page 12  ---
  856.  
  857.  
  858.  
  859.  
  860.  
  861.  
  862.  
  863.  
  864.         want, then release the ALT key. Using the ALT key in this area,
  865.         you can enter a value from 32-255. Again, the background will
  866.         change indicating a change.
  867.  
  868.  
  869.   8. Goto an offset
  870.  
  871.         G
  872.  
  873.         Goto an offset in the file. You are prompted for an offset to go
  874.         to. You can enter either a decimal number or a hexadecimal number.
  875.         If you press ESC while entering a number you will be placed back
  876.         in the View mode with no repositioning taking place.  The
  877.         BACKSPACE key can be used to edit your entry. If you enter an
  878.         offset that is beyond the EOF (or < 0) you will be prompted again
  879.         for a number.
  880.  
  881.         New with version 4.0 * If you've done at least one Goto command,
  882.         you can also select any past offsets you've entered by pressing H,
  883.         (H for History). After pressing H, the most recent offset entered
  884.         is displayed. If you want to see other offsets that are in
  885.         history, press the UP ARROW key. Using the UP and DOWN ARROW keys
  886.         you can see all the offsets in history.  When you've found the
  887.         offset you want to goto just press ENTER.  Pressing ESC while
  888.         viewing the history items will return you to the input offset
  889.         prompt. There can be a maximum of 50 offsets saved in history.
  890.         Anytime a Goto command is done, the offset is added to history.
  891.         The oldest entries will be lost from history when new offsets are
  892.         added and there are already 50 offsets in history.  Duplicate
  893.         offsets are not re-saved to history.
  894.  
  895.         If you are displaying the file offsets in hexadecimal, then a '$'
  896.         character is placed on the input line for you. The '$' character
  897.         tells heXEdit that the number you are entering is in base 16. If
  898.         you were displaying the file offsets in decimal the '$' is not put
  899.         on the input line. You can press the BACKSPACE key to erase the
  900.         '$' if necessary.
  901.  
  902.         To enter the offset, just type in the number, no commas, and press
  903.         ENTER.
  904.  
  905.         Also, if at anytime while entering a number, you enter an 'A'
  906.         through 'F' and you do not have a '$' as the first character, it
  907.         will be inserted into the input line at the beginning and your
  908.         entry will be taken as a hexadecimal number.  For example:
  909.  
  910.                 Keystroke               Screen
  911.                 3                       3
  912.                 5                       35
  913.                 1                       351
  914.                 E                       $351E
  915.                 etc ...
  916.  
  917.  
  918.  
  919.  
  920.  
  921.  ---  heXEdit  -------------------------------------  Page 13  ---
  922.  
  923.  
  924.  
  925.  
  926.  
  927.  
  928.  
  929.  
  930.   9. Hexadecimal offset #'s
  931.  
  932.         H
  933.  
  934.         Change the offset display to base 16, hexadecimal.
  935.  
  936.  
  937.   10. Load a new file
  938.  
  939.         L
  940.  
  941.         You will enter the Loadfile box in order to select a new file (as
  942.         described earlier in this document under 'Loadfile box').
  943.  
  944.         Since you can't leave the edit mode without either saving any
  945.         changes or losing changes, you needn't worry about saving the
  946.         current file before loading a new one.
  947.  
  948.  
  949.   11. Push position on marker stack
  950.  
  951.         M
  952.  
  953.         Your current position in the file can be saved with this command
  954.         and then be retrieved later on.
  955.  
  956.         Your position is saved on a stack. If the stack is full the oldest
  957.         position will be deleted and the rest of the entries will move
  958.         down the stack to make room for the new entry. The maximum number
  959.         of positions you can save is 100. Also, when your position is
  960.         saved, it's location on the stack is reported to you so you can
  961.         see how full the marker stack is.
  962.  
  963.         This command can also be used while searching. If the search
  964.         string is found, you can press 'M' to save that position on the
  965.         marker stack and then continue searching.
  966.  
  967.  
  968.   12. Search again
  969.  
  970.         N
  971.  
  972.         Search again using the last used search string. If there is no
  973.         previous search string, you will be prompted, as if you pressed
  974.         'S', to enter a search string.
  975.  
  976.  
  977.   13. Octal offset #'s
  978.  
  979.         O
  980.  
  981.         Change the offset display to base 8, octal.
  982.  
  983.         If you happen to be looking at a REALLY BIG file, any offsets
  984.  
  985.  
  986.  
  987.  ---  heXEdit  -------------------------------------  Page 14  ---
  988.  
  989.  
  990.  
  991.  
  992.  
  993.  
  994.  
  995.  
  996.         greater than 134,217,727 bytes will appear as '+++++++++' in the
  997.         left side of the main display.
  998.  
  999.  
  1000.   14. Retrieve position from marker stack
  1001.  
  1002.         R
  1003.  
  1004.         While viewing the file, if you do this command you will be moved
  1005.         to the location specified by the top marker stack entry.  Once you
  1006.         have been moved to the new location, the entry you retrieved will
  1007.         be deleted from the marker stack. If there are no markers on the
  1008.         stack, then nothing will happen.
  1009.  
  1010.  
  1011.   15. Search
  1012.  
  1013.         S
  1014.  
  1015.         Search the file for a byte or text sequence. You will be prompted
  1016.         for the type of search (B)yte or (T)ext.
  1017.  
  1018.         New with version 4.0 * If you've done at least one search, you can
  1019.         also select any past items you've searched for by pressing H (H
  1020.         for History) when you are asked for the type of search to perform.
  1021.         After pressing H, the most recent search item is displayed. If you
  1022.         want to see other search items that are in history, press the UP
  1023.         ARROW key. Using the UP and DOWN ARROW keys you can see all the
  1024.         items in history. When you've found the item you want to search
  1025.         for just press ENTER. Pressing ESC while viewing the history items
  1026.         will return you to view mode. There can be a maximum of 50 items
  1027.         saved in history. Anytime a (B)yte or (T)ext search is done, the
  1028.         item is added to history. The oldest items will be lost from
  1029.         history if new items are searched for and there are already 50
  1030.         items in history. Duplicate items are not saved to history.
  1031.  
  1032.         For a byte sequence, enter the bytes in hexadecimal notation then
  1033.         press ENTER.  As with editing, you must enter a complete byte, for
  1034.         the search to work correctly, although I don't check for that
  1035.         here. You can use the BACKSPACE key to go back and make
  1036.         corrections.  The maximum length for a byte sequence is 9 bytes. I
  1037.         think that is plenty long enough, even 4 bytes would probably be
  1038.         enough to find what you're looking for. For example, you might see
  1039.         this prompt :
  1040.  
  1041.                 Enter search bytes :
  1042.  
  1043.         Now you would just press the numbers or letters that make up the
  1044.         bytes you want to search for, like :
  1045.  
  1046.                 D3 45 FF 00 C4 6E
  1047.  
  1048.         There is no need to enter a space between each byte as I do that
  1049.         for you while you're entering your numbers.
  1050.  
  1051.  
  1052.  
  1053.  ---  heXEdit  -------------------------------------  Page 15  ---
  1054.  
  1055.  
  1056.  
  1057.  
  1058.  
  1059.  
  1060.  
  1061.  
  1062.         For a text sequence, just type in the text to search for, no
  1063.         quotes are needed, and press ENTER. The maximum length for a text
  1064.         sequence is 25 characters.  The search is case insensitive.
  1065.  
  1066.         If the search string is found, the display will move to that
  1067.         string's location in the file and will be highlighted at the top
  1068.         of the screen. You can now press any key to continue the search,
  1069.         press 'M' to Mark the position or press ESC to stop searching.
  1070.  
  1071.         While XE is searching, you can press any key to interrupt and stop
  1072.         the search.
  1073.  
  1074.         Just to make things simple for myself, every search starts at the
  1075.         beginning of the file. Even on large files, starting at the
  1076.         beginning to find something you know is near the end doesn't take
  1077.         very long at all (at least not on my 40Mhz 386!).
  1078.  
  1079.         And beginning with v3.5, the searching is done using the
  1080.         Boyer-Moore algorithm. This should significantly speed up
  1081.         searching; on ANY computer.
  1082.  
  1083.  
  1084.   16. Clear marker stack
  1085.  
  1086.         Z
  1087.  
  1088.         This command will delete all entries from the marker stack.
  1089.         Careful, there is no turning back from the results of this
  1090.         command.
  1091.  
  1092.  
  1093.   17. Goto marked position
  1094.  
  1095.         Alt+1 thru Alt+9
  1096.  
  1097.         Using these commands will move you to a previously marked position
  1098.         without deleting the mark information.  The retrieve command 'R'
  1099.         moves you to the last position and deletes the mark, using Alt+1 -
  1100.         Alt+9 does not delete the mark. Alt+1 moves you to the first
  1101.         marked position, Alt+2 moves you to the second marked position,
  1102.         etc etc. If you try to move to a position that has not been marked
  1103.         yet, nothing will happen except a message telling you so.
  1104.  
  1105.  
  1106. J. Other Notes
  1107.  
  1108.         If for some reason you rename XE.EXE you will need to rename the
  1109.         help file, XE.HLP. For example, if you rename XE.EXE to XEDIT.EXE,
  1110.         the help file should be renamed to XEDIT.HLP.
  1111.  
  1112.         And if for some other reason you have XE.EXE loaded under XE, and
  1113.         then save new color information, you may need to force a re-read
  1114.         of the last part of the file to get the correct information
  1115.         loaded.
  1116.  
  1117.  
  1118.  
  1119.  ---  heXEdit  -------------------------------------  Page 16  ---
  1120.  
  1121.  
  1122.  
  1123.  
  1124.  
  1125.  
  1126.  
  1127.  
  1128.         The Loadfile box has a limit of 2500 files or directories that it
  1129.         can display for you. If you change to a directory with more than
  1130.         2500, you will not see all of the files.  2500 is about as high as
  1131.         I can go due to stack space limitations. If you want to load a
  1132.         file that is in a directory with more than 2500 files, you'll have
  1133.         to specify that filename on the command line when you start XE.
  1134.  
  1135.         XE does not support any video modes other than 80x25 text but will
  1136.         work with a monochrome monitor. Just don't forget to include the
  1137.         '/M' option on the command line and then save the color
  1138.         configuration to retain the monochrome 'colors'.
  1139.  
  1140.         This program should NOT be compressed with PKLITE. It will not run
  1141.         if it is. Because, XE reads the current color setup from itself,
  1142.         compressing it with PKLITE will cause a runtime error.
  1143.  
  1144.  
  1145. K. Comments
  1146.  
  1147.  
  1148.         I would STRONGLY suggest that you make a backup copy of any file
  1149.         you're going to modify, just in case you decide later you want the
  1150.         original file back. You should have a backup copy anyway as a
  1151.         matter of safeguarding your files in case of catastrophe.
  1152.  
  1153.         I have a 40Mhz 386dx AT running MS-DOS 6.2. XE should work with
  1154.         most system configurations though.
  1155.  
  1156.         Also, I don't expect any payment for use of this program. Feel
  1157.         FREE to use it how you like, but be careful :).
  1158.  
  1159.  
  1160.         Rob
  1161.  
  1162.  
  1163.  
  1164. L. Appendix
  1165.  
  1166.   1. Version History
  1167.  
  1168.             v1.0  04-08-91 - Initial writing
  1169.             v1.1  05-16-91 - Minor internal changes
  1170.             v1.2  07-04-91 - added Marker commands
  1171.             v1.21 08-03-91 - increased marker stack size to 100
  1172.                              added Z command; clear marker stack
  1173.             v1.3  08-12-91 - added Goto Offset command
  1174.                              fixed a bug or two
  1175.             v2.0  09-25-91 - added Loadfile box (instead of typing in
  1176.                                the filename)
  1177.                              set to video page 0 at startup
  1178.                                (this was done in case you shell out from
  1179.                                another program and that program puts you
  1180.                                in a video page other than 0, like Turbo
  1181.                                Debugger. XE needs to be in video page
  1182.  
  1183.  
  1184.  
  1185.  ---  heXEdit  -------------------------------------  Page 17  ---
  1186.  
  1187.  
  1188.  
  1189.  
  1190.  
  1191.  
  1192.  
  1193.  
  1194.                                0.  XE returns to the video page you
  1195.                                where at before it started when you exit)
  1196.                              added backspace key use while editing (acts
  1197.                                like left arrow key)
  1198.                              added 'D', 'H' and 'O' commands while viewing
  1199.                              changed Help command to 'F1' from 'H'
  1200.                              made Search command case insensitive
  1201.                              added ability to enter a drive designator
  1202.                                on cmd line to start Loadfile box on that drive
  1203.                              and of course fixed some bugs ...
  1204.             v2.1  10-19-91 - decided I better try and trap most of the
  1205.                                I/O, as opposed to only some, for errors,
  1206.                                to avoid a possible run-time error
  1207.                              allow loading of read-only files
  1208.                              allow entry of ASCII chars 32-255 when
  1209.                                editing in ASCII portion of display
  1210.                                (formerly 32-126)
  1211.                              check for and handle extremely long path names
  1212.                                in display
  1213.                              swapped ability to change Help screen color
  1214.                                with Base convert
  1215.                              search command now highlights found text,
  1216.                                (no flashing arrow!)
  1217.                              hidden files (and directories) are lowercase
  1218.                                in Loadfile box
  1219.                              and the usual bug fixes ...
  1220.             v2.11 10-21-91 - fixed base convert color saving and loading
  1221.                                from cfg file
  1222.             v3.0  11-11-91 - fixed pagedown problem of going past EOF on
  1223.                                display for files with a length approaching
  1224.                                that of the buffer size
  1225.                              added '%' into file indicator
  1226.                              you can now call up the ascii chart and
  1227.                                base convert from edit mode with
  1228.                                Alt+A, Alt+B
  1229.                              in edit mode, Pg Up/Dn now just goto first/
  1230.                                last line. column position is not changed
  1231.                              totally new help system  (yea!)
  1232.             v3.01 11-12-91 - fixed extra '%' char left when going from
  1233.                                100% to <100%
  1234.                              allow config file to take on same name as
  1235.                                executable; in case you rename XE.EXE
  1236.             v3.02 11-18-91 - fixed bug when executing from second level
  1237.                                or deeper sub-dir.
  1238.             v3.1  11-25-91 - fixed configuration file saving problem
  1239.                              added ALT+1 thru ALT+9 commands (goto
  1240.                                marked position)
  1241.                              restricted input length for base conversion
  1242.             v3.2  01-23-92 - added colorbox for color selection, instead
  1243.                                of entering numbers.
  1244.             v3.3  01-29-92 - XE.CFG file is now history. Color
  1245.                                information is saved in the executable
  1246.                              added cmd line options /C, /M, /?, ?, /H
  1247.                              slight (very) improvement in display speed
  1248.  
  1249.  
  1250.  
  1251.  ---  heXEdit  -------------------------------------  Page 18  ---
  1252.  
  1253.  
  1254.  
  1255.  
  1256.  
  1257.  
  1258.  
  1259.  
  1260.                              restore cursor from a Ctrl-Brk input
  1261.                              no more editing past the EOF
  1262.             v3.31 02-05-92 - fixed byte search problem with char case
  1263.             v3.32 02-07-92 - fixed byte search problem with char case
  1264.                                (this time for real. haste makes waste...)
  1265.             v3.33 02-23-92 - change Loadfile box to show files in the
  1266.                                current directory of a drive (previously
  1267.                                root dir)
  1268.             v3.4  04-04-92 - added ability to abort searching
  1269.                              update '%' into file indicator during search
  1270.                              added Alt+A for ASCII chart cmd from View mode
  1271.                              added Alt+B for Base convert cmd from View mode
  1272.                              cursor is positioned at location of last search
  1273.                                item when going to edit mode; if that search
  1274.                                item is visible on screen in same file
  1275.                              changed default colors a little
  1276.                              file list in Loadfile box is now sorted by name
  1277.                              fixed PgUp bug in Loadfile box
  1278.             v3.5  04-23-92 - implemented the Boyer-Moore search algorithm
  1279.                                for a definite improvement in search
  1280.                                speed
  1281.             v3.51 06-10-92 - fixed search routine bug
  1282.             v3.52 06-29-92 - ditto
  1283.             v3.53 08-10-92 - allow 'C' (change colors) command in mono;
  1284.                                so you can save the mono colors to XE.
  1285.             v3.54 12-10-92 - allow ESC while editing when only half of
  1286.                                a byte has been changed.
  1287.             v3.6  02-06-93 - show offset of cursor when editing
  1288.                              line wrap cursor when moving
  1289.             v3.61 04-03-93 - fix display for files > 9999999 bytes long
  1290.                              set highlight bar to last position in
  1291.                                Load file box
  1292.             v3.62 04-10-93 - fix runtime error when specifying a legal
  1293.                                but unused drive letter on cmd line.
  1294.             v3.63 04-19-93 - minor change to an included unit
  1295.             v3.64 04-22-93 - allow Hidden attribute bit change on a
  1296.                                subdirectory (via F7 in Loadfile box)
  1297.             v3.65 09-16-93 - fix dash/dots not showing up in display
  1298.             v4.00 12-9-93  - added ALT+D command, shell to DOS/other prog
  1299.                              added history function for searching and
  1300.                                goto offset command
  1301.                              editing cmd ESC, now prompts to discard
  1302.                                chgs or not
  1303.                              changed included unit so Loadfile box can
  1304.                                load 2500 files versus 300!
  1305.                              check for DOS v3.0+ otherwise exit
  1306.                              check available memory, exit if not enough
  1307.             v4.10 02-16-94 - filename first char search in Loadfile box
  1308.                              take out available memory check
  1309.                              XEOPT environment var for options
  1310.                              if offset display is octal and you're at an
  1311.                                offset > 777777777 octal, dsply +++++++++
  1312.                                for offset
  1313.             v4.11 03-23-94 - fix backspace key not backing up a line
  1314.  
  1315.  
  1316.  
  1317.  ---  heXEdit  -------------------------------------  Page 19  ---
  1318.  
  1319.  
  1320.  
  1321.  
  1322.  
  1323.  
  1324.  
  1325.  
  1326.             v4.12 07-12-94 - chg Loadfile box to check for remote drives,
  1327.                                config.sys LASTDRIVE value not used anymore
  1328.                              check for DOS v3.1+ otherwise exit
  1329.             v4.13 07-21-94 - display date/time in Loadfile box of dirs
  1330.                              display volumeid of local, fixed drives
  1331.                              surround drive letter with symbols
  1332.                                representing the device type
  1333.             v4.14 08-03-94 - fix vol label display bug in Loadfile box
  1334.             v4.15 08-07-94 - fix .HLP filename construction bug
  1335.             v4.16 08-13-94 - fix .HLP filename construction bug
  1336.  
  1337.  
  1338.  
  1339.  
  1340.  
  1341.  
  1342.   2. Trademark information
  1343.  
  1344.         'Turbo Pascal' and 'Turbo Debugger' are registered trademarks
  1345.           of Borland International, Inc.
  1346.  
  1347.         'PKLITE' is a registered trademark of PKWARE, Inc.
  1348.  
  1349.  
  1350.  
  1351.  
  1352.  
  1353.  
  1354.  
  1355.  
  1356.  
  1357.  
  1358.  
  1359.  
  1360.  
  1361.  
  1362.  
  1363.  
  1364.  
  1365.  
  1366.  
  1367.  
  1368.  
  1369.  
  1370.  
  1371.  
  1372.  
  1373.  
  1374.  
  1375.  
  1376.  
  1377.  
  1378.  
  1379.  
  1380.  
  1381.  
  1382.  
  1383.  ---  heXEdit  -------------------------------------  Page 20  ---